home *** CD-ROM | disk | FTP | other *** search
/ Almathera Ten Pack 3: CDPD 3 / Almathera Ten on Ten - Disc 3: CDPD3.iso / fish / 726-750 / 726 / powersnap / powersnap.doc < prev    next >
Text File  |  1995-03-18  |  19KB  |  409 lines

  1.  
  2.  
  3.                           PowerSnap 2.0 User Manual
  4.  
  5.                                  Jun 14, 1992
  6.  
  7.  
  8.  
  9. ›1mPreface›0m
  10. ›1m=======›0m
  11.  
  12.    The programs and files in this distribution are freely distributable,
  13. but are also Copyright (c) Nico François.  They may be freely distributed as
  14. long as no more than a nominal fee is charged to cover time and copying costs.
  15.    No commercial usage is permitted without written permission from the
  16. author.  Everything in this distribution must be kept together, in original
  17. unmodified form.
  18.    The above is generally known as freeware.
  19.  
  20.    This program requires Kickstart/Workbench 2.0 or higher to run!
  21.  
  22.    If you have suggestions or remarks about this program, or if you find
  23. any bugs, please let me know.
  24.  
  25.    Contacting the author:
  26.  
  27.      FidoNet:  2:292/603.10 (Nico Francois)
  28.  
  29.      UUCP   :  Nico.Francois@p10.f603.n292.z2.FidoNet.Org
  30.  
  31.      Address:  Nico François
  32.                Corbielaan 13
  33.                B-3060 Bertem
  34.                BELGIUM
  35.  
  36.    If you can please use e-mail.  That way you'll stand a much better chance
  37. of getting a reply quickly.
  38.  
  39.  
  40. ›1mContents›0m
  41. ›1m========›0m
  42.  
  43. 1. An introduction
  44.  
  45. 2. Installation
  46.  
  47. 3. CLI usage
  48.  
  49. 4. Workbench usage
  50.  
  51. 5. Features
  52.  
  53.  
  54. ›1m1. An introduction›0m
  55. ›1m==================›0m
  56.  
  57.    Snap, snap, snap, snap, eggs and snap :-)  Ahem...  (If you don't get this
  58. don't let it bother you if you think I've gone completely bananas :-)
  59.  
  60.    PowerSnap is a utility that allows you to use the mouse to mark characters
  61. anywhere on the screen and paste them somewhere else, like in the CLI or in a
  62. string gadget.  PowerSnap will check what font is used in the window you snap
  63. from and will look for the position of the characters automatically.  It
  64. recognizes all non proportional fonts of up to 24 pixels wide and of any
  65. height so this should cover most fonts used.  Snapping and pasting text is
  66. done using the mouse, making PowerSnap fast and easy to use.
  67.    To try PowerSnap out, double-click its icon to install the handler, move
  68. the mouse over a character on the screen, press the left ALT key and while
  69. keeping this pressed press the left mouse button.  After a short delay
  70. (depends on how big the font is) PowerSnap will either flash the screen,
  71. indicating it hasn't found a character at this position (it is possible
  72. PowerSnap didn't look for the correct font), or the character you are pointing
  73. at will be selected.  Move the mouse while keeping the left ALT key and the
  74. mouse button down to select more characters.  Once you are satisfied with what
  75. you have selected release the left ALT key.  You can now insert the text you
  76. have just snapped by pressing either left ALT + V or left ALT + right mouse
  77. button.
  78.    Both the left ALT and the 'V' keys mentioned in this short explanation are
  79. user-definable (see below).  Also, don't start snapping on a space because
  80. PowerSnap will almost certainly get the character positions wrong.  You CAN
  81. start snapping on a space if you have already snapped in the window.
  82.  
  83.  
  84. ›1m2. Installation›0m
  85. ›1m===============›0m
  86.  
  87.    To install PowerSnap automatically run the installation script.  Install
  88. manually by copying 'PowerSnap' and 'PowerSnap.info' to your C: directory and
  89. 'powersnap-handler' to your L: directory.  'powersnap-handler' does not have
  90. to be in L: but it is best if you put it there, PowerSnap will also find it
  91. if it is in the current directory.
  92.    If you want PowerSnap to be part of your initial startup (so you always
  93. have the comfort of snapping anything anywhere :-) you should put a simple
  94. line saying 'PowerSnap' before the 'EndCLI >NIL:' in your startup-sequence.
  95. If you wish to specify options include these on the same line, like e.g.
  96. 'PowerSnap COLOR 2'.  To disable the copyright message redirect output to NIL:
  97. like in 'PowerSnap >NIL:'.
  98.    Workbench 2.0 users have the following extra possibility:  drag the
  99. PowerSnap icon into the WbStartup drawer of your boot disk/partition.  And
  100. that's all there is to it.  Specify options in the icon's tooltypes.  If you
  101. do it this way you don't have to change your startup-sequence.
  102.  
  103.  
  104. ›1m3. CLI usage›0m
  105. ›1m============›0m
  106.  
  107.    Enter 'PowerSnap ?' for a CLI usage template, 'PowerSnap ??' for a more
  108. detailed usage report:
  109.  
  110.    ›1mPowerSnap 2.0›0m (DATE)
  111.    ›33mCopyright 1992 © Nico François›0m
  112.    Usage: PowerSnap [CX_PRIORITY n] [QUAL qual] [SLQUAL qual] [PASTEKEY char]
  113.                     [COLOR 1-3] [PAQUAL qual] [PREPEND str] [APPEND str]
  114.                     [SNAPCHARS] [SNAPFRAME] [[NO]JOIN] [[NO]XEROX]
  115.        or PowerSnap LIST
  116.        or PowerSnap QUIT
  117.  
  118.    Explanation of the options:
  119.  
  120.    CX_PRIORITY n : Set priority of commodity (default: 0).
  121.    QUAL qual     : Set snap qualifier (qual, default: LALT).
  122.                    This is the qualifier that must be down when you press
  123.                    the left mouse button to start snapping.  This is also the
  124.                    qualifier for inserting the snapped text.  There are two
  125.                    ways to insert snapped text: using the pastekey or using
  126.                    the right mouse button.
  127.    SLQUAL qual   : Set single line qualifier (qual, default: LALT+LSHIFT).
  128.                    When this qualifier is down and you insert snapped text
  129.                    everything will be put on one single line.  All whitespace
  130.                    (spaces and newlines) between words will be changed to a
  131.                    single space.  Very useful for inserting a lot of
  132.                    filenames from a directory for example.
  133.    MULTIQUAL qual: Set MultiSnap qualifier (qual, default: LALT+LSHIFT).
  134.                    When you start snapping with this qualifier the snapped
  135.                    text will be appended after what you snapped before.
  136.                    A newline will be placed in between the snapped texts,
  137.                    so they are all on their own line. Paste snapped text
  138.                    using the single line qualifier to get everything on one
  139.                    line.  Note that the default single line qualifier and
  140.                    the multisnap qualifier are the same.  You can still
  141.                    toggle MultiSnap on or off when you are already snapping.
  142.                    Just change the qualifier, so in the default setup let go
  143.                    or press down the shift key.  There is a small delay of
  144.                    1/8 sec before toggling the snap mode.  This was done so
  145.                    it is less likely that you accidently snap in the wrong
  146.                    mode when you release all qualifiers to stop snapping.
  147.    PASTEKEY c    : Set pastekey (character, default: V).
  148.                    This key is used to insert the snapped text.  Insertion
  149.                    will follow when it is pressed with on of the three
  150.                    possible qualifiers down (QUAL, SLQUAL, PAQUAL).
  151.    SNAPCHARS     : Start with character snap (default).
  152.    SNAPFRAME     : Start with frame snap.
  153.                    PowerSnap has two snap modes: character and frame.  The
  154.                    easiest to explain is frame snap, you just draw a
  155.                    rectangle and everything inside it will be snapped.
  156.                    Character snap will interpret the screen as lines of text
  157.                    (like an editor) and will snap accordingly.
  158.    [NO]JOIN      : Join mode on/off (default: on).
  159.                    Tells PowerSnap if it's ok to join two lines to a single
  160.                    long line when the first line has a non blank character
  161.                    as its last character.  This only works when you are using
  162.                    character or word snap.  Default is JOIN.
  163.    [NO]XEROX     : Xerox insert mode on/off (default: off).
  164.                    When xerox mode is on snapped text will be inserted
  165.                    immediately when you stop snapping.  Default is NOXEROX.
  166.    COLOR 1-3     : Set color of select box (1-3, default: 1).
  167.                    This sets the color of the complemented characters.
  168.                    Try all three and see what you like best.
  169.    MULTICOLOR 1-3: Set color of MultiSnap select box (1-3, default: 2).
  170.                    This sets the color of the complemented characters when
  171.                    doing a MultiSnap. It is best to set this to a different
  172.                    color than the normal snap color.  This way you'll have an
  173.                    easy way to see when you are using MultiSnap.
  174.    PAQUAL qual   : Set pre-/append qualifier (qual, default: LALT+CONTROL).
  175.                    When using this qualifier to insert snapped text a string
  176.                    will be prepended to each line and one will be appended.
  177.    PREPEND str   : Set prepend string (default: "> ").
  178.                    Use this to set the string that will be prepended when you
  179.                    paste with the PAQUAL down.  This string can be up to 15
  180.                    characters long.  To enter a '"' in the string escape it
  181.                    with a '*'.  E.g. 'PowerSnap PREPEND " *" "'.
  182.    APPEND str    : Set append string (default: empty).
  183.                    Use this to set the string that will be appended when you
  184.                    paste with the PAQUAL down.  Can be up to 15 characters.
  185.    [NO]SMARTSPACE: If you do a word snap PowerSnap will normally guess at the
  186.                    boundaries of the word by simply looking for empty chars.
  187.                    If you switch SMARTSPACE on however PowerSnap will really
  188.                    try to recognize the characters and stop at spaces as well
  189.                    as unknown characters.  This way you will no longer snap
  190.                    part of the 'scenery' when doing a word snap.  Only
  191.                    drawback is that it is a bit slower, so it is disabled by
  192.                    default.  If you have a faster Amiga (like the A3000) it
  193.                    is strongly recommended to switch this option on.
  194.                    If you don't exactly understand what I mean try snapping
  195.                    the contents of a 2.0 string gadget (like the one in the
  196.                    'Execute Command...' feature of WB2.0) with SMARTSPACE
  197.                    switched on or off.
  198.  
  199.    Following qualifiers are recognized:
  200.  
  201.    LSHIFT          Left shift key
  202.    RSHIFT          Right shift key
  203.    CONTROL         Control key
  204.    CTRL            Control key
  205.    LALT            Left alt key
  206.    RALT            Right alt key
  207.    LCOMMAND        Left Amiga key
  208.    LAMIGA          Left Amiga key
  209.    RCOMMAND        Right Amiga key
  210.    RAMIGA          Right Amiga key
  211.    MIDBUTTON       Middle mouse button (if you have one :-)
  212.  
  213.    Or any combination of these (separate the qualifiers by a non-alpha
  214. character like a '+', '-' or '|'), e.g. 'LALT+LSHIFT' or 'LALT-LSHIFT'.
  215.  
  216.    You may run PowerSnap again once it has been installed to change the
  217. settings.  Enter 'PowerSnap LIST' for a list of current settings.
  218.    'PowerSnap QUIT' will remove the handler from memory.
  219.  
  220.    Examples:
  221.  
  222.     o PowerSnap PREPEND "Type " APPEND " OPT N"
  223.  
  224.     When you paste some text 'Type ' will be inserted before each line
  225.     and ' OPT N' after.  If you e.g. snap 'PowerSnap.c' and press
  226.     LALT-CTRL-V the following will be inserted: 'Type PowerSnap.c OPT N'
  227.  
  228.    o PowerSnap QUAL LSHIFT+RSHIFT+CONTROL
  229.  
  230.     This sets the snap qualifier to both shift keys plus the control
  231.     key.  This is a rather silly example because unless your name is
  232.     Zaphod Beeblebrox or you are very good at doing things with your
  233.     feet it is quite impossible to snap anything with this qualifier :^)
  234.  
  235.    o PowerSnap PASTEKEY i
  236.  
  237.     Sets the insert key to 'I' instead of 'V'.  So pressing LALT-I
  238.     will feed the text in the clipboard to the keyboard.
  239.  
  240. NOTE: - You can toggle between character/frame snap once you have started
  241.         snapping.  Just keep the left mouse pressed down while you click the
  242.         right one.  Be careful, if you don't keep the left button pressed
  243.         you will insert the text you have marked.
  244.       - PowerSnap has the ability to do word oriented snapping.  To activate
  245.         this double-click the left mouse button when you start snapping.  Note
  246.         that word snapping forces character snapping and frame snapping is no
  247.         longer possible.  See SMARTSPACE on how to improve word snapping.
  248.       - Press the left mouse button while PowerSnap is inserting to abort.
  249.  
  250.  
  251. ›1m4. Workbench usage›0m
  252. ›1m==================›0m
  253.  
  254.    PowerSnap recognizes the following tooltypes (see CLI options for a more
  255. complete explanation):
  256.  
  257.    CX_PRIORITY=n : Priority of commodity (default is 0).
  258.    QUAL=qual     : Snap qualifier (qual, default: LALT).
  259.    SLQUAL=qual   : Single line qualifier (qual, default: LALT+LSHIFT).
  260.    MULTIQUAL=qual: MultiSnap qualifier (qual, default: LALT+LSHIFT).
  261.    PASTEKEY=c    : Pastekey (character, default: V).
  262.    SNAPCHARS     : Start with character snap (default).
  263.    SNAPFRAME     : Start with frame snap.
  264.    COLOR=1-3     : Color of select box (1-3, default: 1).
  265.    MULTICOLOR=1-3: Color of MultiSnap select box (1-3, default: 2).
  266.    JOIN          : Join mode on (default).
  267.    NOJOIN        : Join mode off.
  268.    XEROX         : Xerox insert mode on.
  269.    NOXEROX       : Xerox insert mode off (default).
  270.    PAQUAL=qual   : Pre-/append qualifier (qual, default: LALT+CONTROL).
  271.    PREPEND=str   : Prepend string (default: "> ").
  272.    APPEND=str    : Append string (default: empty).
  273.                    Do *NOT* put quotes around the pre-/append string.
  274.    SMARTSPACE    : Switch SMARTSPACE on for improved word snapping.
  275.    QUIET         : Don't open window informing PowerSnap has been installed
  276.                    or removed.  Useful for people who wish to put PowerSnap
  277.                    in their WbStartup drawer.
  278.  
  279.    Select PowerSnap's icon and choose 'Information' from the 'Icons' menu.
  280. You can now edit PowerSnap's tooltypes, check your manual for more
  281. information.
  282.    Run PowerSnap twice to remove it from memory.
  283.  
  284.  
  285. ›1m5. Features›0m
  286. ›1m===========›0m
  287.  
  288.    o Fully supports the clipboard.device.  You can use snapped text in all
  289.      other programs that supports the clipboard.device.
  290.  
  291.    o Snaps all printable characters, from ' ' (32) to 'ÿ' (255).
  292.  
  293.    o Supports all keymaps.
  294.  
  295.    o Uses a relatively small handler that is about 8K long.  PowerSnap
  296.      uses about 15K of memory once it is installed (excluding memory used
  297.      by the clipboard.device and commodities.library).
  298.  
  299.    o Recognizes all non-proportional fonts to up to 24 pixels wide and of
  300.      any height.  Also recognizes scaled fonts (bitmap and CompuGraphic).
  301.  
  302.    o Recognizes plain, underlined, bold, inverse, bold underlined, inverse
  303.      underlined, inverse bold and inverse bold underlined characters :-)
  304.  
  305.    o Works with fonts with kerning data (like the courier.font supplied
  306.      with Workbench 2.0).
  307.  
  308.    o Will remember character positions in up to 8 windows.  Once you have
  309.      snapped in a window the initial character position will be found
  310.      immediately and you may also start snapping on spaces.
  311.  
  312.    o Joins long lines.
  313.  
  314.    o Pre-/appends strings to pasted text.
  315.  
  316.    o Has a neat single-line mode to paste all you snapped onto one single
  317.      line.  All whitespace and newlines will be changed to spaces.
  318.  
  319.    o Supports a middle mouse button if one exists.  Using the middle button
  320.      as qualifier gives the possibility to snap/paste without touching the
  321.      keyboard!
  322.  
  323.    o Inputhandler is written in assembly for lowest possible overhead.
  324.  
  325.    New features for PowerSnap 2.0:
  326.    ¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯
  327.    o PowerSnap is a standard commodity.  Use the standard commodities
  328.      Exchange program to enable/disable or kill it.
  329.  
  330.    o MultiSnap feature.  Allows you to snap something and add it to what you
  331.      snapped before.  This append-snapping is very useful to pick up several
  332.      words that you might want to join into one long snap.  The snapped
  333.      items are put in the clipboard, each on its own line (with a linefeed
  334.      between them).  You can use the single-line paste to paste them all onto
  335.      one line.
  336.  
  337.    o Recognizes text in all colors.  Text in any color on a background of
  338.      any color will be recognized.
  339.  
  340.    o SMARTSPACE argument to make PowerSnap consider unknown stuff as a space.
  341.      This way you can do _much_ better word snapping in non-shell windows.
  342.  
  343.  
  344.                                                  As always, enjoy !
  345.  
  346.  
  347.                               PROGRAM HISTORY:
  348.  
  349. ******************************************************************************
  350. VERSION 1.0
  351.  
  352.    First release.
  353.  
  354. ******************************************************************************
  355. VERSION 1.1
  356.  
  357.    Fixed bug in reading from clipboard.  Strange things could happen if the
  358.      clipboard did not contain text. Unknown clips are properly ignored now.
  359.    Incompatibility with 'ConClip' (Workbench 2.0, V37) resolved.
  360.    Default COLOR changed to 1.
  361.    Version string embedded for Workbench 2.0 'Version' command.
  362.    To put the record straight:  PowerSnap is not a modified version of
  363.      Snap (by Mikael Karlsson).  It is a completely different program
  364.      that does most of the things Snap does.  A lot of the features and
  365.      ideas in PowerSnap were influenced by (read stolen from :-) Snap
  366.      though.  I just thought I'd mention this because some German magazine
  367.      almost convicted me for plagiarism, oh boy :^D
  368.    The Amiga would hang if you tried to snap something just when a window
  369.      was about to close.  Now all the Intuition functions that open, close
  370.      or modify windows are patched so they will wait until snapping has
  371.      finished.  If you are running Kickstart 2.0, the new Intuition
  372.      functions are also patched.  This should fix all deadlocks.
  373.    New tooltype 'QUIET' added for startup from Workbench without window.
  374.    Tested with Enforcer and Mungwall debugging tools.
  375.  
  376. ******************************************************************************
  377. VERSION 2.0
  378.  
  379.    Only runs on Kickstart 2.0 or higher!
  380.    ¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯
  381.    PowerSnap is a commodity now, so it can be disabled/enabled and killed
  382.      using the Commodities Exchange program.  Note the replacement of the
  383.      'PRIORITY' argument by 'CX_PRIORITY' to set the commodity's priority
  384.      rather than that of the input handler (default is 0).
  385.    PowerSnap's character recognition has been improved.  Before you could
  386.      only snap black or blue text, now you may also snap white text.  In
  387.      fact PowerSnap now recognizes text in any color on a background of
  388.      any color.  How could you ever manage without this! :-)
  389.    New SMARTSPACE and NOSMARTSPACE arguments.  Allow you to switch on much
  390.      better, but slower, word-snap detection.  Once you get used to this
  391.      I think you won't mind it's a bit slower.  It is no problem on faster
  392.      Amigas of course, like the A3000.
  393.    New MultiSnap feature: allows you to add what you snap now to what you
  394.      snapped before.  That way you can e.g. snap several files from a
  395.      directory without having to snap them all at once.
  396.    Now also recognizes LAMIGA, RAMIGA and CTRL as qualifiers.
  397.  
  398. ******************************************************************************
  399.  
  400. PowerSnap 2.0 written by Nico François (Yes, Nico is my first name :-)
  401.               thanks to Jorrit Tyberghein, Ives Aerts & Philip Marivoet for
  402.                         beta testing.
  403.  
  404. (c) 1991/1992 Nico François
  405.  
  406.                                    //
  407.                        Thanks to \X/ Amiga for being the best computer ever !
  408.  
  409.